<p class="Head1"><help:paragraphinfo state="U" number="1"/><help:key-word value="Atn; function" tag="kw66489_1"/><help:link Id="66489">Atn Function [Runtime]</help:link></p>
<p class="Paragraph"><help:paragraphinfo state="U" number="2"/>Trigonometric function that returns the arctangent of a numeric expression. The return value is in the range -Pi/2 to +Pi/2.</p>
<p class="Paragraph"><help:paragraphinfo state="U" number="3" xmlns:help="http://openoffice.org/2000/help"/>The arctangent is the inverse of the tangent function. The Atn Function returns the angle "Alpha", expressed in radians, using the tangent of this angle. The function can also return the angle "Alpha" by comparing the ratio of the length of the side that is opposite of the angle to the length of the side that is adjacent to the angle in a right-angled triangle.</p>
<p class="Paragraph"><help:paragraphinfo state="U" number="4" xmlns:help="http://openoffice.org/2000/help"/>Atn(side opposite the angle/side adjacent to angle)= Alpha</p>
<p class="Paragraph"><help:paragraphinfo state="U" number="10" xmlns:help="http://openoffice.org/2000/help"/><span class="T1">Number:</span> Any numerical expression that represents the ratio of two sides of a right triangle. The Atn function returns the corresponding angle in radians (arctangent).</p>
<p class="Paragraph"><help:paragraphinfo state="U" number="11" xmlns:help="http://openoffice.org/2000/help"/>To convert radians to degrees, multiply radians by 180/pi.</p>
<p class="Paragraph"><help:paragraphinfo state="U" number="14" xmlns:help="http://openoffice.org/2000/help"/>Pi is here the fixed circle constant with the rounded value 3.14159.</p>
<p class="PropText"><help:paragraphinfo state="U" number="16" xmlns:help="http://openoffice.org/2000/help"/>REM The following example calculates for a right-angled triangle</p>
<p class="PropText"><help:paragraphinfo state="U" number="17" xmlns:help="http://openoffice.org/2000/help"/>REM the angle Alpha from the tangent of the angle Alpha:</p>
<p class="PropText"><help:paragraphinfo state="U" number="19" xmlns:help="http://openoffice.org/2000/help"/>REM rounded Pi = 3.14159 is a predefined constant</p>
<p class="PropText"><help:paragraphinfo state="U" number="20" xmlns:help="http://openoffice.org/2000/help"/>Dim d1 As Double</p>
<p class="PropText"><help:paragraphinfo state="U" number="21" xmlns:help="http://openoffice.org/2000/help"/>Dim d2 As Double</p>
<p class="PropText"><help:paragraphinfo state="U" number="22" xmlns:help="http://openoffice.org/2000/help"/>d1 = InputBox$ ("Enter the length of the side adjacent to the angle: ","Adjacent")</p>
<p class="PropText"><help:paragraphinfo state="U" number="23" xmlns:help="http://openoffice.org/2000/help"/>d2 = InputBox$ ("Enter the length of the side opposite the angle: ","Opposite")</p>